import { Field, ObjectType } from '@nestjs/graphql';
import { SharedEntity } from 'src/modules/shared/entities/shared.entity';
import { Column, Entity } from 'typeorm';
@ObjectType()
@Entity('posts_tags')
export class PostsTagsEntity extends SharedEntity {
  @Field({ description: '标签ID' })
  @Column({
    type: 'int',
    name: 'tags_id',
    comment: '标签id',
  })
  tagsId: number;

  @Field({ description: '文章ID' })
  @Column({
    type: 'int',
    name: 'posts_id',
    comment: '文章id',
  })
  postsId: number;
}
